<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
</head>
<body>
<div id="app">
    <ul>
        <li v-for="item in nameList">
          {{item.name}}--{{item.city}}--{{item.price}}元
        </li>
    </ul>
</div>
<!--引入vue文件-->
<script src="https://unpkg.com/vue@3/dist/vue.global.js"></script>
<script>
    const vm= Vue.createApp({//创建一个应用程序实例
        data(){//该函数返回数据对象
          return{
                  nameList:[
                      {name:'洗衣机',city:'上海',price:'8600'},
                      {name:'冰箱',city:'北京',price:'6800'},
                      {name:'空调',city:'广州',price:'5900'}
                  ]
            }
         }
    }).mount('#app'); //在指定的DOM元素上装载应用程序实例的根组件
</script>

</body>
</html>
